﻿using System;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Web;
using System.Web.Mvc;

namespace Model
{

    [MetadataType(typeof(SupplierContact_Metadata))]
    [DisplayName("供应商联系人")]
    public partial class SupplierContact
    {
        public SupplierContact()
        {
            this.Id = Guid.NewGuid();
            this.UserId = new Guid(HttpContext.Current.User.Identity.Name);
        }

        public class SupplierContact_Metadata
        {
            [ScaffoldColumn(false)]
            public Guid Id { get; set; }

            [ScaffoldColumn(false)]
            public Guid UserId { get; set; }

            [DisplayName("供应商")]
            [DropDownList("Supplier", "Id", "SupplierName")]
            [Required]
            public object SupplierId { get; set; }

            [DisplayName("联系人")]
            [Required]
            public object ContactName { get; set; }

            [DisplayName("电话")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            public object telephone { get; set; }

            [DisplayName("手机")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            public object Phone { get; set; }

            [DisplayName("传真")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            public object fax { get; set; }

            [DisplayName("E-mail")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            public object Email { get; set; }
           
            [DisplayName("QQ")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            public object QQ { get; set; }

            [DisplayName("银行卡账号")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            public object ZhangHao { get; set; }

            [DisplayName("描述信息")]
            [DisplayFormat(ConvertEmptyStringToNull = false)]
            [DataType(DataType.MultilineText)]
            public object Description { get; set; }
        }
    }
}
